<html>
<head>
	<title>Serialization benchmark results</title>
	<link href='default.css' rel='stylesheet' type='text/css' />
</head>
<body>

<h2>Results of <span>Northwind database rows serialization</span> benchmarks run at 06/02/2010</h2>
<span class="summary">These benchmarks show the total time in ticks (1/1000ms) that it takes each serializer to serialize and deserialize the first row from each table in the  <a href='http://code.google.com/p/servicestack/source/browse/trunk/Common/Northwind.Benchmarks/Northwind.Common/DataModel/NorthwindData.cs'>Northwind Database</a><strong>10,000</strong> Times. <br/><br/>The full source code of the serialization benchmarks (which generated this report) is <a href='http://code.google.com/p/servicestack/source/browse/trunk/Common/Northwind.Benchmarks/Northwind.Benchmarks.Console/Program.cs'>available here</a>.</span><div id='combined'>
<h3>Combined results of all benchmarks below</h3><table>
<caption>* All times measured in ticks and payload size in bytes</caption><thead><tr><th>Serializer</th><th>Payload size</th><th>Larger than best</th><th>Serialization</th><th>Deserialization</th><th>Total</th><th>Avg per iteration</th><th>Slower than best</th></tr></thead>
<tbody>
<tr class=''><th class='c1'>Microsoft DataContractSerializer</th><td>4097</td><th>4.68x</th><td>2581582</td><td>6930148</td><td>9511730</td><td>951.173</td><th>7.64x</th></tr><tr class=''><th class='c1'>Microsoft JsonDataContractSerializer</th><td>1958</td><th>2.24x</th><td>4627663</td><td>9780495</td><td>14408158</td><td>1440.8158</td><th>11.57x</th></tr><tr class=''><th class='c1'>Microsoft BinaryFormatter</th><td>4927</td><th>5.62x</th><td>6443623</td><td>6016566</td><td>12460189</td><td>1246.0189</td><th>10.00x</th></tr><tr class=''><th class='c1'>NewtonSoft.Json</th><td>2014</td><th>2.30x</th><td>2996547</td><td>7838008</td><td>10834555</td><td>1083.4555</td><th>8.70x</th></tr><tr class='best-size best-time'><th class='c1'>ProtoBuf.net</th><td>876</td><th>1x</th><td>636743</td><td>608836</td><td>1245579</td><td>124.5579</td><th>1x</th></tr><tr class=''><th class='c1'>ServiceStack TypeSerializer</th><td>1560</td><th>1.78x</th><td>1667869</td><td>1339240</td><td>3007109</td><td>300.7109</td><th>2.41x</th></tr>
</tbody>
</table>
</div>
<h3>Results of serializing and deserializing CategoryDto 10,000 times</h3><table>
<caption>* All times measured in ticks and payload size in bytes</caption><thead><tr><th>Serializer</th><th>Payload size</th><th>Larger than best</th><th>Serialization</th><th>Deserialization</th><th>Total</th><th>Avg per iteration</th><th>Slower than best</th></tr></thead>
<tbody>
<tr class=''><th class='c1'>Microsoft DataContractSerializer</th><td>275</td><th>4.74x</th><td>159981</td><td>421452</td><td>581433</td><td>58.1433</td><th>6.90x</th></tr><tr class=''><th class='c1'>Microsoft JsonDataContractSerializer</th><td>95</td><th>1.64x</th><td>271249</td><td>625196</td><td>896445</td><td>89.6445</td><th>10.64x</th></tr><tr class=''><th class='c1'>Microsoft BinaryFormatter</th><td>329</td><th>5.67x</th><td>403867</td><td>396558</td><td>800425</td><td>80.0425</td><th>9.50x</th></tr><tr class=''><th class='c1'>NewtonSoft.Json</th><td>110</td><th>1.90x</th><td>153919</td><td>429041</td><td>582960</td><td>58.296</td><th>6.92x</th></tr><tr class='best-size best-time'><th class='c1'>ProtoBuf.net</th><td>58</td><th>1x</th><td>46379</td><td>37876</td><td>84255</td><td>8.4255</td><th>1x</th></tr><tr class=''><th class='c1'>ServiceStack TypeSerializer</th><td>87</td><th>1.5x</th><td>85871</td><td>47126</td><td>132997</td><td>13.2997</td><th>1.58x</th></tr>
</tbody>
</table>
<h3>Results of serializing and deserializing CustomerDto 10,000 times</h3><table>
<caption>* All times measured in ticks and payload size in bytes</caption><thead><tr><th>Serializer</th><th>Payload size</th><th>Larger than best</th><th>Serialization</th><th>Deserialization</th><th>Total</th><th>Avg per iteration</th><th>Slower than best</th></tr></thead>
<tbody>
<tr class=''><th class='c1'>Microsoft DataContractSerializer</th><td>482</td><th>3.74x</th><td>268601</td><td>838999</td><td>1107600</td><td>110.76</td><th>6.15x</th></tr><tr class=''><th class='c1'>Microsoft JsonDataContractSerializer</th><td>256</td><th>1.98x</th><td>450891</td><td>997768</td><td>1448659</td><td>144.8659</td><th>8.04x</th></tr><tr class=''><th class='c1'>Microsoft BinaryFormatter</th><td>635</td><th>4.92x</th><td>814850</td><td>670626</td><td>1485476</td><td>148.5476</td><th>8.24x</th></tr><tr class=''><th class='c1'>NewtonSoft.Json</th><td>271</td><th>2.10x</th><td>307655</td><td>752132</td><td>1059787</td><td>105.9787</td><th>5.88x</th></tr><tr class='best-size best-time'><th class='c1'>ProtoBuf.net</th><td>129</td><th>1x</th><td>83342</td><td>96868</td><td>180210</td><td>18.021</td><th>1x</th></tr><tr class=''><th class='c1'>ServiceStack TypeSerializer</th><td>202</td><th>1.57x</th><td>193844</td><td>125178</td><td>319022</td><td>31.9022</td><th>1.77x</th></tr>
</tbody>
</table>
<h3>Results of serializing and deserializing EmployeeDto 10,000 times</h3><table>
<caption>* All times measured in ticks and payload size in bytes</caption><thead><tr><th>Serializer</th><th>Payload size</th><th>Larger than best</th><th>Serialization</th><th>Deserialization</th><th>Total</th><th>Avg per iteration</th><th>Slower than best</th></tr></thead>
<tbody>
<tr class=''><th class='c1'>Microsoft DataContractSerializer</th><td>851</td><th>2.43x</th><td>393273</td><td>1134219</td><td>1527492</td><td>152.7492</td><th>5.18x</th></tr><tr class=''><th class='c1'>Microsoft JsonDataContractSerializer</th><td>598</td><th>1.71x</th><td>739667</td><td>2024648</td><td>2764315</td><td>276.4315</td><th>9.37x</th></tr><tr class=''><th class='c1'>Microsoft BinaryFormatter</th><td>1092</td><th>3.12x</th><td>1299892</td><td>1009741</td><td>2309633</td><td>230.9633</td><th>7.83x</th></tr><tr class=''><th class='c1'>NewtonSoft.Json</th><td>607</td><th>1.73x</th><td>654437</td><td>1789702</td><td>2444139</td><td>244.4139</td><th>8.28x</th></tr><tr class='best-size best-time'><th class='c1'>ProtoBuf.net</th><td>350</td><th>1x</th><td>136906</td><td>158136</td><td>295042</td><td>29.5042</td><th>1x</th></tr><tr class=''><th class='c1'>ServiceStack TypeSerializer</th><td>495</td><th>1.41x</th><td>323766</td><td>314742</td><td>638508</td><td>63.8508</td><th>2.16x</th></tr>
</tbody>
</table>
<h3>Results of serializing and deserializing EmployeeTerritoryDto 10,000 times</h3><table>
<caption>* All times measured in ticks and payload size in bytes</caption><thead><tr><th>Serializer</th><th>Payload size</th><th>Larger than best</th><th>Serialization</th><th>Deserialization</th><th>Total</th><th>Avg per iteration</th><th>Slower than best</th></tr></thead>
<tbody>
<tr class=''><th class='c1'>Microsoft DataContractSerializer</th><td>233</td><th>12.94x</th><td>173319</td><td>415882</td><td>589201</td><td>58.9201</td><th>9.88x</th></tr><tr class=''><th class='c1'>Microsoft JsonDataContractSerializer</th><td>38</td><th>2.11x</th><td>248991</td><td>568708</td><td>817699</td><td>81.7699</td><th>13.72x</th></tr><tr class=''><th class='c1'>Microsoft BinaryFormatter</th><td>234</td><th>13x</th><td>298043</td><td>326095</td><td>624138</td><td>62.4138</td><th>10.47x</th></tr><tr class=''><th class='c1'>NewtonSoft.Json</th><td>53</td><th>2.94x</th><td>153332</td><td>400150</td><td>553482</td><td>55.3482</td><th>9.29x</th></tr><tr class='best-size best-time'><th class='c1'>ProtoBuf.net</th><td>18</td><th>1x</th><td>41643</td><td>17967</td><td>59610</td><td>5.961</td><th>1x</th></tr><tr class=''><th class='c1'>ServiceStack TypeSerializer</th><td>43</td><th>2.39x</th><td>73160</td><td>37831</td><td>110991</td><td>11.0991</td><th>1.86x</th></tr>
</tbody>
</table>
<h3>Results of serializing and deserializing OrderDetailDto 10,000 times</h3><table>
<caption>* All times measured in ticks and payload size in bytes</caption><thead><tr><th>Serializer</th><th>Payload size</th><th>Larger than best</th><th>Serialization</th><th>Deserialization</th><th>Total</th><th>Avg per iteration</th><th>Slower than best</th></tr></thead>
<tbody>
<tr class=''><th class='c1'>Microsoft DataContractSerializer</th><td>282</td><th>0x</th><td>193876</td><td>538103</td><td>731979</td><td>73.1979</td><th>0x</th></tr><tr class=''><th class='c1'>Microsoft JsonDataContractSerializer</th><td>74</td><th>0x</th><td>351299</td><td>684117</td><td>1035416</td><td>103.5416</td><th>0x</th></tr><tr class=''><th class='c1'>Microsoft BinaryFormatter</th><td>315</td><th>0x</th><td>455433</td><td>438657</td><td>894090</td><td>89.409</td><th>0x</th></tr><tr class=''><th class='c1'>NewtonSoft.Json</th><td>94</td><th>0x</th><td>285934</td><td>711993</td><td>997927</td><td>99.7927</td><th>0x</th></tr><tr class='failed'><th class='c1'>ProtoBuf.net</th><td>21</td><th>0x</th><td>60018</td><td>-1</td><td>60017</td><td>6.0017</td><th>0x</th></tr><tr class=''><th class='c1'>ServiceStack TypeSerializer</th><td>76</td><th>0x</th><td>139606</td><td>83407</td><td>223013</td><td>22.3013</td><th>0x</th></tr>
</tbody>
</table>
<h3>Results of serializing and deserializing OrderDto 10,000 times</h3><table>
<caption>* All times measured in ticks and payload size in bytes</caption><thead><tr><th>Serializer</th><th>Payload size</th><th>Larger than best</th><th>Serialization</th><th>Deserialization</th><th>Total</th><th>Avg per iteration</th><th>Slower than best</th></tr></thead>
<tbody>
<tr class=''><th class='c1'>Microsoft DataContractSerializer</th><td>615</td><th>5.69x</th><td>350241</td><td>916996</td><td>1267237</td><td>126.7237</td><th>6.59x</th></tr><tr class=''><th class='c1'>Microsoft JsonDataContractSerializer</th><td>366</td><th>3.39x</th><td>747711</td><td>1676694</td><td>2424405</td><td>242.4405</td><th>12.60x</th></tr><tr class=''><th class='c1'>Microsoft BinaryFormatter</th><td>758</td><th>7.02x</th><td>1118991</td><td>768233</td><td>1887224</td><td>188.7224</td><th>9.81x</th></tr><tr class=''><th class='c1'>NewtonSoft.Json</th><td>366</td><th>3.39x</th><td>611648</td><td>1583494</td><td>2195142</td><td>219.5142</td><th>11.41x</th></tr><tr class='best-size best-time'><th class='c1'>ProtoBuf.net</th><td>108</td><th>1x</th><td>88827</td><td>103539</td><td>192366</td><td>19.2366</td><th>1x</th></tr><tr class=''><th class='c1'>ServiceStack TypeSerializer</th><td>253</td><th>2.34x</th><td>297585</td><td>215198</td><td>512783</td><td>51.2783</td><th>2.67x</th></tr>
</tbody>
</table>
<h3>Results of serializing and deserializing ProductDto 10,000 times</h3><table>
<caption>* All times measured in ticks and payload size in bytes</caption><thead><tr><th>Serializer</th><th>Payload size</th><th>Larger than best</th><th>Serialization</th><th>Deserialization</th><th>Total</th><th>Avg per iteration</th><th>Slower than best</th></tr></thead>
<tbody>
<tr class=''><th class='c1'>Microsoft DataContractSerializer</th><td>452</td><th>11.3x</th><td>240901</td><td>693665</td><td>934566</td><td>93.4566</td><th>14.14x</th></tr><tr class=''><th class='c1'>Microsoft JsonDataContractSerializer</th><td>187</td><th>4.68x</th><td>426950</td><td>1004511</td><td>1431461</td><td>143.1461</td><th>21.66x</th></tr><tr class=''><th class='c1'>Microsoft BinaryFormatter</th><td>508</td><th>12.7x</th><td>603455</td><td>586012</td><td>1189467</td><td>118.9467</td><th>18.00x</th></tr><tr class=''><th class='c1'>NewtonSoft.Json</th><td>189</td><th>4.72x</th><td>343288</td><td>1020406</td><td>1363694</td><td>136.3694</td><th>20.64x</th></tr><tr class='best-size best-time'><th class='c1'>ProtoBuf.net</th><td>40</td><th>1x</th><td>49223</td><td>16859</td><td>66082</td><td>6.6082</td><th>1x</th></tr><tr class=''><th class='c1'>ServiceStack TypeSerializer</th><td>163</td><th>4.08x</th><td>155662</td><td>137830</td><td>293492</td><td>29.3492</td><th>4.44x</th></tr>
</tbody>
</table>
<h3>Results of serializing and deserializing RegionDto 10,000 times</h3><table>
<caption>* All times measured in ticks and payload size in bytes</caption><thead><tr><th>Serializer</th><th>Payload size</th><th>Larger than best</th><th>Serialization</th><th>Deserialization</th><th>Total</th><th>Avg per iteration</th><th>Slower than best</th></tr></thead>
<tbody>
<tr class=''><th class='c1'>Microsoft DataContractSerializer</th><td>209</td><th>19x</th><td>145203</td><td>407095</td><td>552298</td><td>55.2298</td><th>10.86x</th></tr><tr class=''><th class='c1'>Microsoft JsonDataContractSerializer</th><td>38</td><th>3.45x</th><td>246532</td><td>546563</td><td>793095</td><td>79.3095</td><th>15.59x</th></tr><tr class=''><th class='c1'>Microsoft BinaryFormatter</th><td>223</td><th>20.27x</th><td>324769</td><td>360431</td><td>685200</td><td>68.52</td><th>13.47x</th></tr><tr class=''><th class='c1'>NewtonSoft.Json</th><td>38</td><th>3.45x</th><td>132790</td><td>333346</td><td>466136</td><td>46.6136</td><th>9.16x</th></tr><tr class='best-size best-time'><th class='c1'>ProtoBuf.net</th><td>11</td><th>1x</th><td>33144</td><td>17725</td><td>50869</td><td>5.0869</td><th>1x</th></tr><tr class=''><th class='c1'>ServiceStack TypeSerializer</th><td>32</td><th>2.91x</th><td>85483</td><td>30953</td><td>116436</td><td>11.6436</td><th>2.29x</th></tr>
</tbody>
</table>
<h3>Results of serializing and deserializing ShipperDto 10,000 times</h3><table>
<caption>* All times measured in ticks and payload size in bytes</caption><thead><tr><th>Serializer</th><th>Payload size</th><th>Larger than best</th><th>Serialization</th><th>Deserialization</th><th>Total</th><th>Avg per iteration</th><th>Slower than best</th></tr></thead>
<tbody>
<tr class=''><th class='c1'>Microsoft DataContractSerializer</th><td>235</td><th>6.91x</th><td>164244</td><td>716830</td><td>881074</td><td>88.1074</td><th>10.10x</th></tr><tr class=''><th class='c1'>Microsoft JsonDataContractSerializer</th><td>64</td><th>1.88x</th><td>292036</td><td>641652</td><td>933688</td><td>93.3688</td><th>10.70x</th></tr><tr class=''><th class='c1'>Microsoft BinaryFormatter</th><td>269</td><th>7.91x</th><td>390274</td><td>391430</td><td>781704</td><td>78.1704</td><th>8.96x</th></tr><tr class=''><th class='c1'>NewtonSoft.Json</th><td>64</td><th>1.88x</th><td>156601</td><td>376892</td><td>533493</td><td>53.3493</td><th>6.12x</th></tr><tr class='best-size best-time'><th class='c1'>ProtoBuf.net</th><td>34</td><th>1x</th><td>42860</td><td>44368</td><td>87228</td><td>8.7228</td><th>1x</th></tr><tr class=''><th class='c1'>ServiceStack TypeSerializer</th><td>54</td><th>1.59x</th><td>182920</td><td>122129</td><td>305049</td><td>30.5049</td><th>3.50x</th></tr>
</tbody>
</table>
<h3>Results of serializing and deserializing SupplierDto 10,000 times</h3><table>
<caption>* All times measured in ticks and payload size in bytes</caption><thead><tr><th>Serializer</th><th>Payload size</th><th>Larger than best</th><th>Serialization</th><th>Deserialization</th><th>Total</th><th>Avg per iteration</th><th>Slower than best</th></tr></thead>
<tbody>
<tr class=''><th class='c1'>Microsoft DataContractSerializer</th><td>497</td><th>4.56x</th><td>515862</td><td>888028</td><td>1403890</td><td>140.389</td><th>8.73x</th></tr><tr class=''><th class='c1'>Microsoft JsonDataContractSerializer</th><td>255</td><th>2.34x</th><td>940044</td><td>1070565</td><td>2010609</td><td>201.0609</td><th>12.50x</th></tr><tr class=''><th class='c1'>Microsoft BinaryFormatter</th><td>611</td><th>5.61x</th><td>734094</td><td>842916</td><td>1577010</td><td>157.701</td><th>9.80x</th></tr><tr class=''><th class='c1'>NewtonSoft.Json</th><td>255</td><th>2.34x</th><td>344887</td><td>795956</td><td>1140843</td><td>114.0843</td><th>7.09x</th></tr><tr class='best-size best-time'><th class='c1'>ProtoBuf.net</th><td>109</td><th>1x</th><td>78239</td><td>82638</td><td>160877</td><td>16.0877</td><th>1x</th></tr><tr class=''><th class='c1'>ServiceStack TypeSerializer</th><td>180</td><th>1.65x</th><td>185778</td><td>106829</td><td>292607</td><td>29.2607</td><th>1.82x</th></tr>
</tbody>
</table>
<h3>Results of serializing and deserializing TerritoryDto 10,000 times</h3><table>
<caption>* All times measured in ticks and payload size in bytes</caption><thead><tr><th>Serializer</th><th>Payload size</th><th>Larger than best</th><th>Serialization</th><th>Deserialization</th><th>Total</th><th>Avg per iteration</th><th>Slower than best</th></tr></thead>
<tbody>
<tr class=''><th class='c1'>Microsoft DataContractSerializer</th><td>248</td><th>13.05x</th><td>169957</td><td>496982</td><td>666939</td><td>66.6939</td><th>9.66x</th></tr><tr class=''><th class='c1'>Microsoft JsonDataContractSerializer</th><td>61</td><th>3.21x</th><td>263592</td><td>624190</td><td>887782</td><td>88.7782</td><th>12.86x</th></tr><tr class=''><th class='c1'>Microsoft BinaryFormatter</th><td>268</td><th>14.11x</th><td>455388</td><td>664524</td><td>1119912</td><td>111.9912</td><th>16.22x</th></tr><tr class=''><th class='c1'>NewtonSoft.Json</th><td>61</td><th>3.21x</th><td>137990</td><td>356889</td><td>494879</td><td>49.4879</td><th>7.17x</th></tr><tr class='best-size best-time'><th class='c1'>ProtoBuf.net</th><td>19</td><th>1x</th><td>36180</td><td>32860</td><td>69040</td><td>6.904</td><th>1x</th></tr><tr class=''><th class='c1'>ServiceStack TypeSerializer</th><td>51</td><th>2.68x</th><td>83800</td><td>201424</td><td>285224</td><td>28.5224</td><th>4.13x</th></tr>
</tbody>
</table>
</body>
</html>

